<?php

class UserProfile extends Eloquent
{
	public static $timestamps = false;
	public static $table = 'users_profiles';
	public static $key = 'profileid';
	public static $rules = array( 
					    		'fullname' => 'required', 
					    		'fullname' => 'required', 
					    		'emel' => 'required|email|unique:users_profiles', 
					    		'postcode' => 'required|Numeric'
					    	);

	
	public static function validate($data){
		return Validator::make($data, Static::$rules);
	}

     public function user()
     {
          return $this->belongs_to('User');
     }

}
